package org.study.event.core.eventbus.impl;

import org.study.event.core.eventbus.AbstractGuavaEventBusManager;

import com.google.common.eventbus.EventBus;

/***
 * 阻塞式的调用方式
 * 
 * @author 陈波
 *
 */
public class GuavaEventBusManager extends AbstractGuavaEventBusManager {

	@Override
	public void initEventBus() {
		if (this.identifier != null) {
			this.eventBus = new EventBus(identifier);
			return;
		}
		if (this.subscriberExceptionHandler != null) {
			this.eventBus = new EventBus(subscriberExceptionHandler);
			return;
		}

		this.eventBus = new EventBus();
	}

}
